package com.zhiyou100.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.zhiyou100.mapper.UserMapper;
import com.zhiyou100.model.User;
import com.zhiyou100.service.UserService;

@Service
@Transactional
public class UserServiceImpl implements UserService {
	@Autowired
	private UserMapper userMapper;
	@Override
	public int selectUserByEmail(String email) {
		// TODO Auto-generated method stub
		return userMapper.selectUserByEmail(email);
	}

	@Override
	public int insertUser(User user) {
		// TODO Auto-generated method stub
		return userMapper.insertUser(user);
	}

	@Override
	public User selectUserById(int id) {
		// TODO Auto-generated method stub
		return userMapper.selectUserById(id);
	}

	@Override
	public int checkUser(User user) {
		// TODO Auto-generated method stub
		return userMapper.checkUser(user);
	}

	@Override
	public User selectUserInfoByEmail(String email) {
		// TODO Auto-generated method stub
		return userMapper.selectUserInfoByEmail(email);
	}

	@Override
	public int updateUserInfo(User user) {
		// TODO Auto-generated method stub
		return userMapper.updateUserInfo(user);
	}

	@Override
	public int updateUserHeadurl(User user) {
		// TODO Auto-generated method stub
		return userMapper.updateUserHeadurl(user);
	}

	



}
